'****************************************************************************'
'                                                                            '
' Copyright (C) 2010 Muhammad alaa                                           '
'                                                                            '
' This program is free software; you can redistribute it and/or modify       '
' it under the terms of the GNU General Public License as published by       '
' the Free Software Foundation; either version 2 of the License, or          '
' (at your option) any later version.                                        '
'                                                                            '
' This program is distributed in the hope that it will be useful,            '
' but WITHOUT ANY WARRANTY; without even the implied warranty of             '
' MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the              '
' GNU General Public License for more details.                               '
'                                                                            '
' You should have received a copy of the GNU General Public License along    '
' with this program; if not, write to the Free Software Foundation, Inc.,    '
' 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.                '
'                                                                            '
'****************************************************************************'

Namespace OLE

    <ComImport()> _
    <InterfaceType(ComInterfaceType.InterfaceIsIUnknown)> _
    <Guid(IID.OLE.IFont)> _
    Public Interface IFont
        <PreserveSig()> Function get_Name(<Out(), MarshalAs(UnmanagedType.BStr)> ByRef pName As String) As <MarshalAs(UnmanagedType.Error)> Integer
        <PreserveSig()> Function put_Name(<MarshalAs(UnmanagedType.BStr)> ByVal pName As String) As <MarshalAs(UnmanagedType.Error)> Integer
        <PreserveSig()> Function get_Size(<Out()> ByRef psize As Long) As <MarshalAs(UnmanagedType.Error)> Integer
        <PreserveSig()> Function put_Size(ByVal psize As Long) As <MarshalAs(UnmanagedType.Error)> Integer
        <PreserveSig()> Function get_Bold(<MarshalAs(UnmanagedType.Bool), Out()> ByRef pbold As Boolean) As <MarshalAs(UnmanagedType.Error)> Integer
        <PreserveSig()> Function put_Bold(<MarshalAs(UnmanagedType.Bool)> ByVal pbold As Boolean) As <MarshalAs(UnmanagedType.Error)> Integer
        <PreserveSig()> Function get_Italic(<MarshalAs(UnmanagedType.Bool), Out()> ByRef pitalic As Boolean) As <MarshalAs(UnmanagedType.Error)> Integer
        <PreserveSig()> Function put_Italic(<MarshalAs(UnmanagedType.Bool)> ByVal pitalic As Boolean) As <MarshalAs(UnmanagedType.Error)> Integer
        <PreserveSig()> Function get_Underline(<MarshalAs(UnmanagedType.Bool), Out()> ByVal punderline As Boolean) As <MarshalAs(UnmanagedType.Error)> Integer
        <PreserveSig()> Function put_Underline(<MarshalAs(UnmanagedType.Bool)> ByVal punderline As Boolean) As <MarshalAs(UnmanagedType.Error)> Integer
        <PreserveSig()> Function get_Strikethrough(<MarshalAs(UnmanagedType.Bool), Out()> ByRef pstrikethrough As Boolean) As <MarshalAs(UnmanagedType.Error)> Integer
        <PreserveSig()> Function put_Strikethrough(<MarshalAs(UnmanagedType.Bool)> ByVal pstrikethrough As Boolean) As <MarshalAs(UnmanagedType.Error)> Integer
        <PreserveSig()> Function get_Weight(<Out()> ByRef pweight As Short) As <MarshalAs(UnmanagedType.Error)> Integer
        <PreserveSig()> Function put_Weight(ByVal pweight As Short) As <MarshalAs(UnmanagedType.Error)> Integer
        <PreserveSig()> Function get_Charset(<Out()> <MarshalAs(UnmanagedType.I2)> ByRef pweight As Short) As <MarshalAs(UnmanagedType.Error)> Integer
        <PreserveSig()> Function put_Charset(ByVal pcharset As Short) As <MarshalAs(UnmanagedType.Error)> Integer
        <PreserveSig()> Function get_hFont(<Out()> ByRef phFont As IntPtr) As <MarshalAs(UnmanagedType.Error)> Integer
        <PreserveSig()> Function Clone(<Out()> ByRef ppfont As IFont) As <MarshalAs(UnmanagedType.Error)> Integer
        <PreserveSig()> Function IsEqual(ByRef pfontOther As IFont) As <MarshalAs(UnmanagedType.Error)> Integer
        <PreserveSig()> Function SetRatio(ByVal cyLogical As Integer, ByVal cyHimetric As Integer) As <MarshalAs(UnmanagedType.Error)> Integer
        <PreserveSig()> Function QueryTextMetrics(<Out()> ByRef ptm As TextMetricW) As <MarshalAs(UnmanagedType.Error)> Integer
        <PreserveSig()> Function AddRefHfont(ByVal hFont As IntPtr) As <MarshalAs(UnmanagedType.Error)> Integer
        <PreserveSig()> Function ReleaseHfont(ByVal hFont As IntPtr) As <MarshalAs(UnmanagedType.Error)> Integer
        <PreserveSig()> Function SetHdc(ByVal hdc As IntPtr) As <MarshalAs(UnmanagedType.Error)> Integer
    End Interface

End Namespace
